package com.birdman.s2m.controller;


import javax.annotation.Resource;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestMapping;

import com.birdman.s2m.service.UserService;

@Controller
@RequestMapping("/user")
public class UserController {
  @Resource
  private UserService userService;
 
  @RequestMapping("/ShowUser")
  public String toIndex(HttpServletRequest request,HttpServletResponse response,Model model){
      String string=request.getParameter("user");
      System.out.println("string");
     // response.setContentType("application/json;charset=UTF-8");
      //JSONObject object=(JSONObject) new JSONObject().put("userId",1);
     // try {
	//	response.getWriter().println(object.toString());
	//} catch (IOException e) {
	//	e.printStackTrace();
	//}
   // int userId = Integer.parseInt(request.getParameter("id"));
  //  User user = this.userService.getUserById(userId);
   //model.addAttribute("user", user);
   // return "showUser";
      return null;
  }
}
